<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://www.springframework.org/tags" prefix="s"%>
<%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%>
<%@ page session="false"%>
<%@ page pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>Member list</title>
<META http-equiv="Content-Type" content="text/html;charset=UTF-8">
<link href="<c:url value="/resources/css/normalize.css" />" rel="stylesheet" type="text/css" />
<link href="<c:url value="/resources/css/lib.css" />" rel="stylesheet" type="text/css" />
<link href="<c:url value="/resources/css/style.css" />" rel="stylesheet" type="text/css" />

<script src="<c:url value="/resources/jquery/plugin/cookie/jquery.cookie.js" />"></script>
<script src="<c:url value="/resources/jquery/1.6/jquery.js" />"></script>
<script src="<c:url value="/resources/scripts/regionUtil.js" />"></script> 
<script src="<c:url value="/resources/scripts/pager.js" />"></script>
<style>

</style>
<body>
<input type="hidden" name="regionId" id="regionId" />
<p id="regionSelectorContainer"></p>
<table>
	<thead>
		<tr>
			<th>id</th>
			<th>name</th>
			<th>username</th>
			<th>password</th>
			<th>reg Date</th>
			<th>email</th>
			<th>region</th>
			<th>tel</th>
			<th>fax</th>
			<th>address</th>
			<th>postCode</th>
			<th>mobile</th>
			<th>操作</th>
		</tr>
	</thead>
	<tbody>
	<c:forEach var="m" items="${results.items}">
		<tr>
			<td>${m.id}</td>
			<td>${m.name}</td>
			<td>${m.username}</td>
			<td>${m.password}</td>
			<td>${m.regDate}</td>
			<td>${m.email}</td>
			<td>${m.region.name}</td>
			<td>${m.tel}</td>
			<td>${m.fax}</td>
			<td>${m.address}</td>
			<td>${m.postCode}</td>
			<td>${m.mobile}</td>
			<td>Delete, Promote</td>
		</tr>
	</c:forEach>
	</tbody>
</table>
<div id="pager" class="pager f12 mt10 mb10"></div>
</body>
</html>
<script>
	$(document).ready(function() {
        var pager = new Pager(${results.page}, 10, 3, ${results.total}, '#pager', '<c:url value="/search?keyword=" />${searchCriteria.keyword}&categoryId=${searchCriteria.categoryId}&regionId=${searchCriteria.regionId}');
        pager.createPagerBar('#pager');
    });
</script>
